﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace WebApp
{
    public partial class index : System.Web.UI.Page
    {
        protected override void OnInit(EventArgs e)
        {
            base.OnInit(e);

            Response.Write("this is form init function");
        }

        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {

            }
        }

        protected void btnFaviator_Click(object sender, EventArgs e)
        {
            string value = this.chbfruitlist.SelectedValue;
            System.Text.StringBuilder sb = new System.Text.StringBuilder();
            foreach (ListItem li in chbfruitlist.Items)
            {
                if (li.Selected)
                {
                    sb.Append(li.Text + "----" + li.Value);
                }
            }

            Response.Write(sb.ToString());
        }
    }
}